DEMO: Let's learn a new coding term called dot notation!

We use dot notation to assign command to specific sprites, like this: name.action()

  • When we have multiple sprites in our program, we need to use dot notation to tell different sprites what to do.
  • Click Run to learn more! When you're finished with the demo, click Submit and Next to move on.

To navigate the page using the TAB key, first press ESC to exit the code editor.

athlete = codesters.Sprite("player1") athlete.move_right(200) athlete2 = codesters.Sprite("player2") athlete2.move_right(100)
  • Run Code
  • Submit Work
  • Next Activity
  • Show Console
  • Reset Code Editor
  • Codesters How To (opens in a new tab)